﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using ProjectWebNhac.BUS;
using System.Data;

namespace ProjectWebNhac.GUI.User
{
    public partial class ChiTietPlayList : System.Web.UI.Page
    {
        int MaPlaylist;
        PlaylistBus plbus = new PlaylistBus();
        DataTable dt = new DataTable();
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                if (Request["MaPlaylist"] != null)
                {
                    MaPlaylist = Convert.ToInt16(Request["MaPlaylist"]);
                    loadtrang();
                }
                loadtrang();
            }
        }
        private void loadtrang()
        {
            rePlayList.DataSource = plbus.LayDsBaiHatPlaylist(MaPlaylist);
            rePlayList.DataBind();

            dt = plbus.laythongtinplaylist(MaPlaylist);
            lbNgayTao.Text=dt.Rows[0]["NgayTao"].ToString();
            lbTenPlaylist.Text=dt.Rows[0]["TenPlaylist"].ToString();


        }
    }
}